MButtonList – A button list that attaches new buttons aligned vertically.


Creation: MButtonList_New(text$, x, y, pixelwidth)


text$ - The text that is displayed on the initial button.

x – Pixel X coordinate for the top left corner of the button list.

y – Pixel Y coordinate for the top left corner of the button list.

pixelwidth – The width of the button list in pixels.


Functions:

MButtonList_Add(index, text$)

Adds a new button to the bottom of the button list. Returns sub-index for the button.


MButtonList_ClearSelected(index)

Clears the pressed status of the button list.


MButtonList_Delete(index)

Deletes the button list.


MButtonList_Disable(index, buttonIndex)

Disables a button in the button list.


MButtonList_Draw(index)

Draws the button list to screen.


MButtonList_Enable(index, buttonIndex)

Enables a button in the button list.


MButtonList_GetCount(index)

Returns the number of buttons in the button list. 0=none


MButtonList_GetSelected(index)

Returns whether button is pressed status. 0=no ; sub-index of button pressed.


MbuttonList_SetText(index, buttonIndex, text$)

Sets the text on the button.